
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib prefix="sj" uri="/struts-jquery-tags"%>
<!DOCTYPE html>
<html>
    <head>
        <sj:head />
        <title>Manage Location</title>
        <script src="js/jquery.cookie.js"></script>
        <script src="js/coms.js"></script>
           <script src="js/bootstrap.min.js"></script>
    </head>
    <body>
          <s:include value="/jsp/header.jsp">
            <s:param name="user" value="#session.user.username" />
        </s:include>
        <div class="container-fluid">
            <div class="row-fluid">
                <div class="span3">
                    <s:action name="selectMenu" executeResult="true"/>
                </div>
                <div class="span9">
                    <div class="hero-unit">

                       <s:form action="inputLocation_">
                            <s:submit value="Add"/>
                        </s:form>


            <table align="center" cellpadding="5">
                 <tr style="background:  #0088cc">
                    <th><s:text name="fieldLabel.locationName"/></th>
                    <th><s:text name="fieldLabel.address"/></th>
                    <th>Action</th>
                </tr>

                <s:iterator value="locationList" status="locationStatus">
                    <s:if test="#locationStatus.even == true">
                        <tr style="background: #f2f4fe">
                        </s:if>
                        <s:else>
                        <tr style="background: #dae2fc">
                        </s:else>
                        <td> <s:property value="locationName"/></td>
                        <td> <s:property value="address"/></td>
                      
                         <td> 
                                        <div class="btn-group">
                                            <a class="btn btn-primary" href="#"><i class="icon-th-large icon-white"></i> </a>
                                            <a class="btn btn-primary dropdown-toggle" data-toggle="dropdown" href="#"><span class="caret"></span></a>
                                            <ul class="dropdown-menu">
                                                <li><a href="<s:url action="editLocation_%{id}" />"><i class="icon-pencil"></i> <s:text name="label.edit"/></a></li>
                                                <li><a href="<s:url action="deleteLocation_%{id}" />"><i class="icon-trash"></i> <s:text name="label.delete"/></a></li>
                                            </ul>
                                        </div>
                                    </td> 
                    </tr>
                </s:iterator>
            </table>

              </div>
                    <div class="row-fluid">

                    </div>
                </div>
            </div>
        </div>
        <s:include value="/jsp/footer.jsp"/>
    </body>
</html>
